<!DOCTYPE html>
<html data-dpr="1" style="font-size: 37.5px;">
<head>
    <title>老师选择列表</title>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <meta name="keywords" content="轻轻家教,家教上门一对一,名师家教,小学奥数,初中数学,家教app">
    <meta name="description"
          content="轻轻家教是目前国内领先的大型家教APP，已携手教育培训行业巨头学而思，致力于通过大数据为学生匹配适合的老师上门授课，按次付费有保障，让家长足不出户找到合适的好老师，快速提高学生成绩。">
    <meta name="applicable-device" content="mobile">
    <meta name="apple-touch-fullscreen" content="yes">
    <meta name="format-detection" content="telephone=no">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta http-equiv="Cache-Control" content="no-transform">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=no">
    <link rel="stylesheet" type="text/css" href="__TMPL__/public/assets/css/style1503546983737.css">
    <link rel="stylesheet" type="text/css" href="__TMPL__/public/assets/css/common_css-1fe12f85234e85ce973d3535dad4b1d1.css">
    <link rel="stylesheet" type="text/css" href="__TMPL__/public/assets/css/findteacher-1432cf62987fc6a7965911249168d389.css">
    <link rel="stylesheet" type="text/css" href="__TMPL__/public/assets/css/animate.css">
    <link rel="canonical" href="https://m.changingedu.com/list/">
    <link rel="stylesheet" href="__TMPL__/public/assets/css/animate.css">

    <script src="http://cdn.static.runoob.com/libs/jquery/1.10.2/jquery.min.js">
    </script>
    <script src="https://cdn.jsdelivr.net/npm/vue"></script>

    <link rel="stylesheet" href="https://cdn.bootcss.com/weui/1.1.2/style/weui.min.css">
    <link rel="stylesheet" href="https://cdn.bootcss.com/jquery-weui/1.2.0/css/jquery-weui.min.css">

    <script src="https://cdn.bootcss.com/jquery/1.11.0/jquery.min.js"></script>
    <script src="https://cdn.bootcss.com/jquery-weui/1.2.0/js/jquery-weui.min.js"></script>
    <style type="text/css">
     .amap-indoor-map .label-canvas {
        position: absolute;
        top: 0;
        left: 0
        }

    .amap-indoor-map .highlight-image-con * {
        pointer-events: none
    }

    .amap-indoormap-floorbar-control .panel-box {
        background-color: rgba(255, 255, 255, .9);
        border-radius: 3px;
        border: 1px solid #ccc
    }

    .amap-indoormap-floorbar-control .select-dock {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        box-sizing: border-box;
        height: 30px;
        border: solid #4196ff;
        border-width: 0 2px;
        border-radius: 2px;
        pointer-events: none;
        background: linear-gradient(to bottom, #f6f8f9 0, #e5ebee 50%, #d7dee3 51%, #f5f7f9 100%)
    }

    .amap-indoor-map .transition {
        transition: opacity .2s
    }



    .amap-indoormap-floorbar-control .transition {
        transition: top .2s, margin-top .2s
    }

    .amap-indoormap-floorbar-control .select-dock:after, .amap-indoormap-floorbar-control .select-dock:before {
        content: "";
        position: absolute;
        width: 0;
        height: 0;
        left: 0;
        top: 10px;
        border: solid transparent;
        border-width: 4px;
        border-left-color: #4196ff
    }

    .amap-indoormap-floorbar-control .select-dock:after {
        right: 0;
        left: auto;
        border-left-color: transparent;
        border-right-color: #4196ff
    }

    .amap-indoormap-floorbar-control.is-mobile {
        width: 37px
    }

    .amap-indoormap-floorbar-control.is-mobile .floor-btn {
        height: 35px;
        line-height: 35px
    }

    .amap-indoormap-floorbar-control.is-mobile .select-dock {
        height: 35px;
        top: 36px
    }

    .amap-indoormap-floorbar-control.is-mobile .select-dock:after, .amap-indoormap-floorbar-control.is-mobile .select-dock:before {
        top: 13px
    }

    .amap-indoormap-floorbar-control.is-mobile .floor-list-box {
        height: 105px
    }

    .amap-indoormap-floorbar-control .floor-list-item .floor-btn {
        color: #555;
        font-family: "Times New Roman", sans-serif, "Microsoft Yahei";
        font-size: 16px
    }

    .amap-indoormap-floorbar-control .floor-list-item.selected .floor-btn {
        color: #000
    }

    .amap-indoormap-floorbar-control .floor-btn {
        height: 28px;
        line-height: 28px;
        overflow: hidden;
        cursor: pointer;
        position: relative;
        -webkit-touch-callout: none;
        -webkit-user-select: none;
        -khtml-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        user-select: none
    }

    .amap-indoormap-floorbar-control .floor-btn:hover {
        background-color: rgba(221, 221, 221, .4)
    }

    .amap-indoormap-floorbar-control .floor-minus, .amap-indoormap-floorbar-control .floor-plus {
        position: relative;
        text-indent: -1000em
    }

    .amap-indoormap-floorbar-control .floor-minus:after, .amap-indoormap-floorbar-control .floor-plus:after {
        content: "";
        position: absolute;
        margin: auto;
        top: 9px;
        left: 0;
        right: 0;
        width: 0;
        height: 0;
        border: solid transparent;
        border-width: 10px 8px;
        border-top-color: #777
    }

    .amap-indoormap-floorbar-control .floor-minus.disabled, .amap-indoormap-floorbar-control .floor-plus.disabled {
        opacity: .3
    }

    .amap-indoormap-floorbar-control .floor-plus:after {
        border-bottom-color: #777;
        border-top-color: transparent;
        top: -3px
    }

    .amap-indoormap-floorbar-control .floor-list-box {
        max-height: 153px;
        position: relative;
        overflow-y: hidden
    }

    .amap-indoormap-floorbar-control .floor-list {
        margin: 0;
        padding: 0;
        list-style: none
    }

    .amap-indoormap-floorbar-control .floor-list-item {
        position: relative
    }

    .amap-indoormap-floorbar-control .floor-btn.disabled, .amap-indoormap-floorbar-control .floor-btn.disabled *, .amap-indoormap-floorbar-control.with-indrm-loader * {
        -webkit-pointer-events: none !important;
        pointer-events: none !important
    }

    .amap-indoormap-floorbar-control .with-indrm-loader .floor-nonas {
        opacity: .5
    }

    .amap-indoormap-floorbar-control .amap-indrm-loader {
        -moz-animation: amap-indrm-loader 1.25s infinite linear;
        -webkit-animation: amap-indrm-loader 1.25s infinite linear;
        animation: amap-indrm-loader 1.25s infinite linear;
        border: 2px solid #91A3D8;
        border-right-color: transparent;
        box-sizing: border-box;
        display: inline-block;
        overflow: hidden;
        text-indent: -9999px;
        width: 13px;
        height: 13px;
        border-radius: 7px;
        position: absolute;
        margin: auto;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0
    }

    @-moz-keyframes amap-indrm-loader {
        0% {
            -moz-transform: rotate(0);
            transform: rotate(0)
        }
        100% {
            -moz-transform: rotate(360deg);
            transform: rotate(360deg)
        }
    }

    @-webkit-keyframes amap-indrm-loader {
        0% {
            -webkit-transform: rotate(0);
            transform: rotate(0)
        }
        100% {
            -webkit-transform: rotate(360deg);
            transform: rotate(360deg)
        }
    }

    @keyframes amap-indrm-loader {
        0% {
            -moz-transform: rotate(0);
            -ms-transform: rotate(0);
            -webkit-transform: rotate(0);
            transform: rotate(0)
        }
        100% {
            -moz-transform: rotate(360deg);
            -ms-transform: rotate(360deg);
            -webkit-transform: rotate(360deg);
            transform: rotate(360deg)
        }
    }</style>
    <style>
    html {
        color: #000;
        background: #fff;
        overflow-y: scroll;
        -webkit-text-size-adjust: 100%;
        -ms-text-size-adjust: 100%
    }

    html * {
        outline: 0;
        -webkit-text-size-adjust: none;
        -webkit-tap-highlight-color: rgba(0, 0, 0, 0)
    }

    html, body {
        font-family: sans-serif
    }

    body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, code, form, fieldset, legend, input, textarea, p, blockquote, th, td, hr, button, article, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section {
        margin: 0;
        padding: 0
    }

    input, select, textarea {
        font-size: 100%
    }

    table {
        border-collapse: collapse;
        border-spacing: 0
    }

    fieldset, img {
        border: 0
    }

    abbr, acronym {
        border: 0;
        font-variant: normal
    }

    del {
        text-decoration: line-through
    }

    address, caption, cite, code, dfn, em, th, var {
        font-style: normal;
        font-weight: 500
    }

    ol, ul {
        list-style: none
    }

    caption, th {
        text-align: left
    }

    h1, h2, h3, h4, h5, h6 {
        font-size: 100%;
        font-weight: 500
    }

    q:before, q:after {
        content: ''
    }

    sub, sup {
        font-size: 75%;
        line-height: 0;
        position: relative;
        vertical-align: baseline
    }

    sup {
        top: -.5em
    }

    sub {
        bottom: -.25em
    }

    a:hover {
        text-decoration: underline
    }

    ins, a {
        text-decoration: none
    }</style>
    <style>
        a{
            text-decoration:none;
            color: #0c0c0c;
        }
    </style>
</head>
<body style="font-size: 12px;background-color: white">
<div class="js-container">
    <div class="page">
        <div class="com-wrap rel certWrap teacher_head_header teacher-list" style="position: initial">
            <div class="top-fixed-wrap">

                <!--头部开始-->
                <div class="new_m_header">
                    <header>

                            <a href="{:url('portal/index/index')}" onclick="history.back()" class="returnBack" id="returnBack">
                            </a>


                        <h3 id="course-list-wrap">
                            <span class="ellipsis">{$Request.param.subject}<div id="msg"></div></span>
                        </h3>
                    </header>
                </div>
                <!--头部结束-->
                <!--条件开始-->
                <div class="search-bar-wrap" style="    border-bottom: 1px #eeefef solid;">

                    <div class="search-bar" style="border: none">
                        <div class="js-drop" id="sort" data-external="actioncode=c_sort">
                            <div>
                                排序
                                <em class="arrow-down"></em>
                                <em class="arrow-down rotate" style="display:none;"></em>
                            </div>
                        </div>
                        <div class="js-drop" id="grade" data-external="actioncode=gradechoice">
                            <div>
                                年级
                                <em class="arrow-down"></em>
                                <em class="arrow-down rotate" style="display:none;"></em>
                            </div>
                        </div>
                        <div class="js-drop" id="city">
                            <div style="text-align: center;padding: 0px">
                                <!--城市-->
                                周口
                               <!-- <em class="arrow-down"></em>
                                <em class="arrow-down rotate" style="display:none;"></em>-->
                            </div>
                        </div>
                        <div class="js-drop" id="screen" data-external="actioncode=c_screen">
                            <div>
                                筛选
                                <em class="arrow-down"></em>
                                <em class="arrow-down rotate" style="display:none;"></em>
                            </div>
                        </div>
                    </div>
                    <div class="search-drop-wrap">
                        <div   id="sort_list" style="display:none;height: auto;">
                            <div class="search-drop" style="background-color:#fff">
                                <div class="intel-drop" style="overflow:hidden">
                                    <div class="swiper-wrapper">
                                        <div class="swiper-slide">
                                            <!--active是改变字体颜色-->
                                            <!--hidden是隐藏对号-->
                                            <div class="intel-item sort_item rel ">
                                                <em class="icon-confirm hidden " data-type="default"></em>智能排序</div>

                                            <div class="intel-item sort_item rel  " data-type="4">
                                                <em class="icon-confirm hidden"></em>价格最高</div>

                                            <!--<div class="intel-item sort_item rel " data-type="5">-->
                                                <!--<em class="icon-confirm hidden"></em> 授课最多-->
                                            <!--</div>-->
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <div   id="grade_list" style="display:none;height: auto;">
                            <div class="grade-choose-list cf" style="overflow:hidden">
                                <div class="swiper-wrapper">
                                    <div class="swiper-slide">

                                        <div class="item">
                                            <div class="title">
                                                小学
                                            </div>
                                            <div class="single-item-wrap cf">
                                                <div class="single-item  grade_item " data-id="1"
                                                     data-external="actioncode=gradechoice">一年级</div>

                                                <div class="single-item  grade_item" data-id="2"
                                                     data-external="actioncode=gradechoice">二年级</div>

                                                <div class="single-item grade_item " data-id="3"
                                                     data-external="actioncode=gradechoice">三年级</div>

                                                <div class="single-item grade_item " data-id="4"
                                                     data-external="actioncode=gradechoice">四年级</div>

                                                <div class="single-item grade_item " data-id="5"
                                                     data-external="actioncode=gradechoice">五年级</div>

                                                <div class="single-item grade_item " data-id="6"
                                                     data-external="actioncode=gradechoice">六年级</div>

                                            </div>
                                        </div>
                                        <div class="item mtR40">
                                            <div class="title">
                                                初中
                                            </div>
                                            <div class="single-item-wrap cf">
                                                <div class="single-item grade_item " data-id="7"
                                                     data-external="actioncode=gradechoice">初一</div>

                                                <div class="single-item grade_item " data-id="8"
                                                     data-external="actioncode=gradechoice">初二</div>

                                                <div class="single-item grade_item " data-id="9"
                                                     data-external="actioncode=gradechoice">初三</div>

                                            </div>
                                        </div>
                                        <div class="item mtR40">
                                            <div class="title">
                                                高中
                                            </div>
                                            <div class="single-item-wrap cf">
                                                <div class="single-item grade_item " data-id="10"
                                                     data-external="actioncode=gradechoice">高一</div>

                                                <div class="single-item grade_item " data-id="11"
                                                     data-external="actioncode=gradechoice">高二</div>

                                                <div class="single-item grade_item " data-id="12"
                                                     data-external="actioncode=gradechoice">高三</div>

                                            </div>
                                        </div>


                                    </div>
                                </div>
                            </div>
                        </div>
                        <div   id="city_list"   style="display:none;height: auto;">
                            <div class="city_wrap">
                                <div class="city_choose_list cf">
                                    <div class="single-item city_item " data-id="default">不限</div>

                                    <div class="single-item city_item " data-id="3">北京</div>

                                    <div class="single-item city_item " data-id="4">上海</div>

                                    <div class="single-item city_item " data-id="5">天津</div>

                                    <div class="single-item city_item " data-id="6">重庆</div>

                                    <div class="single-item city_item " data-id="48">深圳</div>

                                    <div class="single-item city_item " data-id="151">武汉</div>

                                    <div class="single-item city_item " data-id="25">厦门</div>

                                    <div class="single-item city_item " data-id="26">泉州</div>

                                    <div class="single-item city_item " data-id="30">莆田</div>

                                    <div class="single-item city_item " data-id="32">漳州</div>

                                    <div class="single-item city_item " data-id="47">广州</div>

                                    <div class="single-item city_item " data-id="191">南京</div>

                                    <div class="single-item city_item " data-id="351">杭州</div>

                                    <div class="single-item city_item " data-id="51">佛山</div>

                                    <div class="single-item city_item " data-id="53">江门</div>

                                    <div class="single-item city_item " data-id="54">中山</div>

                                    <div class="single-item city_item " data-id="55">汕头</div>

                                    <div class="single-item city_item " data-id="56">湛江</div>

                                    <div class="single-item city_item " data-id="71">桂林</div>

                                    <div class="single-item city_item " data-id="82">贵阳</div>

                                    <div class="single-item city_item " data-id="109">石家庄</div>

                                    <div class="single-item city_item " data-id="113">唐山</div>

                                    <div class="single-item city_item " data-id="24">福州</div>

                                    <div class="single-item city_item " data-id="120">郑州</div>

                                    <div class="single-item city_item " data-id="152">襄阳</div>

                                    <div class="single-item city_item " data-id="254">济南</div>

                                    <div class="single-item city_item " data-id="173">衡阳</div>

                                    <div class="single-item city_item " data-id="179">株洲</div>

                                    <div class="single-item city_item " data-id="282">西安</div>

                                    <div class="single-item city_item " data-id="7">合肥</div>

                                    <div class="single-item city_item " data-id="168">长沙</div>

                                    <div class="single-item city_item " data-id="192">苏州</div>

                                    <div class="single-item city_item " data-id="198">扬州</div>

                                    <div class="single-item city_item " data-id="193">常州</div>

                                    <div class="single-item city_item " data-id="203">盐城</div>

                                    <div class="single-item city_item " data-id="196">无锡</div>

                                    <div class="single-item city_item " data-id="215">沈阳</div>

                                    <div class="single-item city_item " data-id="216">大连</div>

                                    <div class="single-item city_item " data-id="229">呼和浩特</div>

                                    <div class="single-item city_item " data-id="230">包头</div>

                                    <div class="single-item city_item " data-id="231">赤峰</div>

                                    <div class="single-item city_item " data-id="50">东莞</div>

                                    <div class="single-item city_item " data-id="255">青岛</div>

                                    <div class="single-item city_item " data-id="257">烟台</div>

                                    <div class="single-item city_item " data-id="271">太原</div>

                                    <div class="single-item city_item " data-id="273">大同</div>

                                    <div class="single-item city_item " data-id="201">南通</div>

                                    <div class="single-item city_item " data-id="292">成都</div>

                                    <div class="single-item city_item " data-id="293">绵阳</div>

                                    <div class="single-item city_item " data-id="320">乌鲁木齐</div>

                                    <div class="single-item city_item " data-id="335">昆明</div>

                                    <div class="single-item city_item " data-id="204">南昌</div>

                                    <div class="single-item city_item " data-id="352">宁波</div>

                                    <div class="single-item city_item " data-id="353">嘉兴</div>

                                    <div class="single-item city_item " data-id="354">绍兴</div>

                                    <div class="single-item city_item " data-id="355">温州</div>

                                    <div class="single-item city_item " data-id="357">湖州</div>

                                    <div class="single-item city_item " data-id="358">金华</div>

                                    <div class="single-item city_item " data-id="360">台州</div>
                                </div>
                            </div>
                        </div>
                        <div   id="screen_list"  class="group-search-wrap rel" style="display:none;height: auto;">
                            <div class="group-search">
                                <div class="swiper-wrapper">
                                    <div class="swiper-slide">

                                        <div class="sex-wrap ">
                                            <div class="item rel">
                                                <div class="title">
                                                    性别
                                                </div>
                                                <div class="single-item-wrap cf m_item_g">
                                                    <div class="male single-item  m_item" data-id="1">男</div>
                                                    <div class="female single-item  m_item " data-id="0">女</div>
                                                </div>
                                            </div>
                                        </div>
                                        <div class="school_age_range-wrap ">
                                            <div class="item">
                                                <div class="title">
                                                    教龄
                                                </div>
                                                <div class="single-item-wrap cf y_item_g">
                                                    <div class="single-item  y_item" data-upper="5">5年以下</div>
                                                    <div class="single-item  y_item" data-lower="6" data-upper="10">5-10年</div>
                                                    <div class="single-item y_item " data-lower="10">10年以上</div>
                                                </div>
                                            </div>
                                        </div>


                                    </div>
                                </div>
                            </div>
                            <div class="bottom-wrap">
                                <div class="flex-wrap">
                                    <div class="js-reset">重置</div>
                                    <div class="rel js-confirm"><a>确定</a></div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>


                <!--条件结束-->
            </div>
            <div class="course-view-wrap"> </div>
            <div id="zs"></div>
            <!--信息展示开始-->
            <div class="content"  style="background-color: #FFFFFF; width: 100%;height:100%;margin-top: 80px;position:absolute;margin-bottom:45px;padding:0px; overflow: hidden;">
                <div class="list-main-mian weui-form-preview infinite weui-pull-to-refresh" id="listwrap"
                     style="height:100%; margin-top: 1px;overflow:auto;  z-index: 1">
                    <!--下拉刷新-->
                    <div class="weui-pull-to-refresh__layer" style="padding: 5px;height: 25px;margin-top: -7px">
                        <div class="weui-pull-to-refresh__arrow"></div>
                        <div class="weui-pull-to-refresh__preloader"></div>
                        <div class="down">下拉刷新</div>
                        <div class="up">释放刷新</div>
                        <div class="refresh">正在刷新</div>
                    </div>
                    <div  id="list" class="list-wrap-new weui-form-preview" style="padding-top: 0rem;">
                        <!--内容展示区域-->
                    </div>
                    <!--加载更多-->
                    <div class="weui-loadmore" style="padding-bottom:30px;height:20px">
                        <i class="weui-loading"></i>
                        <span class="weui-loadmore__tips">正在加载</span>
                    </div>
                </div>
            </div>

            <!--信息展示结束-->

        </div>
    </div>
</div>
</body>

<script>
    var sort="";
    var grade="";
    var city="";
    var screensex="";
    var screenedu="";
    function change(e) {
        //根据条件列表是否展开，改变条件总项的字体颜色和箭头
        var v= $(e).find('em');
        if( $(e+'_list').css("display")=='none' ) {
            $(e).css("color","#666");
            v.last().css("display",'none');
        }
        if($(e+'_list').css("display")=='block'){
            $(e).css("color","#23cd77");
            v.last().css("display",'block');
        }
    }
    function list(e) {
        $("#"+e+"_list").on('mousedown',function(event){
            event.stopPropagation();//阻止mousedown 事件冒泡（注意只阻止了mousedown事件）
            event.preventDefault();//阻止当前元素默认事件
            $('.'+e+'_item ').bind('click', function(){
                //选中改样式
                $('.'+e+'_item ').removeClass('active');
                $(this).addClass('active');

                var checkText=$(this).text();//获取选中的文本
                //选中某一项时，是条件总项的文本同步
                var text=" <div>"+$(this).text()+
                    " <em class=\"arrow-down\"></em>\n" +
                    " <em class=\"arrow-down rotate\"></em>\n" +
                    " </div>"
                $('#'+e).html(text);
                //只用两个排序：科目和一个筛选条件，让不参与的条件总项回复
                if(e=="sort"){
                    sort=checkText;
                    grade="";
                    city="";
                    screenedu="";
                    screensex="";
                }
                if(e=="grade"){
                    grade=checkText;
                    sort="";
                    city="";
                    screenedu="";
                    screensex="";
                }
                if(e=="city"){
                    city=checkText;
                    sort="";
                    grade="";
                    screenedu="";
                    screensex="";
                }
                loadlist1();
                $("#"+e+"_list").hide();
                change("#"+e);

            });
        });
    }

    $(document).on('mousedown',function(){
//达到点击文档任一区域，隐藏条件列表和条件总项
        $('#sort_list').hide();
        $('#grade_list').hide();
        $('#city_list').hide();
        $('#screen_list').hide();
        change('#sort');
        change('#grade');
        change('#city');
        change('#screen');

    });
    $('#sort').on('mousedown',function(event){
        //点击条件总项，展开条件列表，改条件总项样式
        event.stopPropagation();//阻止mousedown 事件冒泡（注意只阻止了mousedown事件）
        event.preventDefault();//阻止当前元素默认事件
        $('#sort_list').toggle();//或者使用这种方式实现显现隐藏效果
        change('#sort');
        $('#grade_list').hide();
        $('#city_list').hide();
        $('#screen_list').hide();
        change('#grade');
        change('#city');
        change('#screen');
    });
    $('#grade').on('mousedown',function(event){
        //点击条件总项，展开条件列表，改条件总项样式
        event.stopPropagation();//阻止mousedown 事件冒泡（注意只阻止了mousedown事件）
        event.preventDefault();//阻止当前元素默认事件
        $('#grade_list').toggle();//或者使用这种方式实现显现隐藏效果
        change('#grade');
        $('#sort_list').hide();
        $('#city_list').hide();
        $('#screen_list').hide();
        change('#sort');
        change('#city');
        change('#screen');

    });
   /* $('#city').on('mousedown',function(event){
        //点击条件总项，展开条件列表，改条件总项样式
        event.stopPropagation();//阻止mousedown 事件冒泡（注意只阻止了mousedown事件）
        event.preventDefault();//阻止当前元素默认事件
        $('#city_list').toggle();//或者使用这种方式实现显现隐藏效果
        change('#city');
        $('#sort_list').hide();
        $('#grade_list').hide();
        $('#screen_list').hide();
        change('#sort');
        change('#grade');
        change('#screen');
    });*/
    $('#screen').on('mousedown',function(event){
        event.stopPropagation();//阻止mousedown 事件冒泡（注意只阻止了mousedown事件）
        event.preventDefault();//阻止当前元素默认事件
        $('#screen_list').toggle();//或者使用这种方式实现显现隐藏效果
        change('#screen');
        $('#sort_list').hide();
        $('#grade_list').hide();
        $('#city_list').hide();
        change('#sort');
        change('#grade');
        change('#city');

    });
    list('sort');
    list('grade');
    list('city');
    //单独处理“筛选”
    $("#screen_list").on('mousedown',function(event){

        event.stopPropagation();//阻止mousedown 事件冒泡（注意只阻止了mousedown事件）
        event.preventDefault();//阻止当前元素默认事件
        $('.m_item ').bind('click', function(){
            //选中改样式
            $('.m_item ').removeClass('active');
            $(this).addClass('active');
        });

        $('.y_item ').bind('click', function(){
            //选中改样式
            $('.y_item ').removeClass('active');
            $(this).addClass('active');
        });

        $('.js-reset').bind('click', function(){
            //重置
            $('.m_item_g').find('.m_item').removeClass('active');
            $('.y_item_g').find('.y_item').removeClass('active');
        });

        $('.js-confirm').bind('click', function(){
            //获取选中文本，全是null，就不请求数据
             screensex=$('.m_item_g').find('.active').text();
             screenedu=$('.y_item_g').find('.active').text();
            grade="";
            sort="";
            city="";
            loadlist1();
            $('#screen_list').hide();
            change("#screen");
        });

    });

    // **************************************************************

    var pages = 1;
    var loading = false;  //状态标记
    $(function () {
        loadlist();
    })
    //=========================下拉刷新
    $("#listwrap").pullToRefresh().on("pull-to-refresh", function () {
        setTimeout(function () {
            pages = 1;
            $("#list").html("");
            loadlist();
            if (loading) loading = false;
            $("#listwrap").pullToRefreshDone(); // 重置下拉刷新
        }, 1500);   //模拟延迟
    });
    //============================滚动加载
    $("#listwrap").infinite().on("infinite", function () {
        console.log("加载");
        if (loading) return;
        loading = true;
        pages++; //页数
        $('.weui-loadmore').show();
        setTimeout(function () {
            loadlist();
            loading = false;
        }, 1500);   //模拟延迟
    });
    // =======加载数据loadlist();
    function loadlist() {
        console.log("sort:"+sort);
        console.log("grade:"+grade);
        console.log("city:"+city);
        console.log("screensex:"+screensex);
        console.log("screenedu:"+screenedu);
        var str = "";
        $.ajax({
            type:"post",
            url:"{:url('/portal/Type/type')}",
            dataType:'JSON',
            data:{sort:sort,grade:grade,city:city,screensex:screensex,screenedu:screenedu,sub:"{$Request.param.subject}",page:pages},
            error: function (){
                $(".weui-loadmore").hide();
                str += "<div class=\"weui-cells__title\" >暂无数据</div>";
                $("#list").append(str);
            },
            success: function (data) {
                if (data.length > 0){
                    console.log(data);
                    for(var k in data){
                        str=str+" <a style=\"text-decoration:none;color:black\" href=\"{:url('/portal/detail/detail/id/')}"+data[k].id+"\">"+
                                "    <div data-external=\"actioncode=list\">\n" +
                            "                        <div class=\"item\" data-id=\"785349041\" data-external=\"actioncode=list\" style=\"border:none\">\n" +
                            "                            <div class=\"border_wrap\">\n" +
                            "                                <div class=\"header cf rel\">\n" +
                            "\n" +
                            "                                    <!--头像开始-->\n" +
                            "                                    <div class=\"rel img\">\n" +
                            "                                        <img src=\"__TMPL__/public/assets/images/demo/techer1.jpg\"\n" +
                            "                                             alt=\"暂无图片\" class=\"fl\">\n" +
                            "                                    </div>\n" +
                            "                                    <!--头像结束-->\n" +
                            "\n" +
                            "                                    <!--内容开始-->\n" +
                            "                                    <div class=\"info\">\n" +
                            "\n" +
                            "                                        <!--上 介绍-->\n" +
                            "                                        <div class=\"rel cf nick_wrap\">\n" +
                            "                                            <div class=\"price-wrap abs bold\">\n" +
                            "                                                <h1 class=\"bold\">¥"+data[k].price+"<span> 起</span></h1>\n" +
                            "                                            </div>\n" +
                            "                                            <span class=\"txt ellipsis  \">"+data[k].grade+ data[k].subject+ data[k].name+"老师</span>\n" +
                            "                                        </div>\n" +
                            "                                        <!--上-->\n" +
                            "\n" +
                            "                                        <!--中 时间-->\n" +
                            "                                        <div class=\"t_info\"  style=\"margin-top: 4px;\">\n" +
                            "                                           <span style=\"color: #ffb812;font-size: 15px\">★★★★★</span>  <span>授课"+data[k].teach_time+"小时</span> | <span>教龄"+data[k].school_age+"年</span>\n" +
                            "                                        </div>\n" +
                            "                                        <!--中-->\n" +
                            "\n" +
                            "                                        <!--下 标签-->\n" +
                            "                                        <div class=\"extra_tags cf\" style=\"margin-top: 9px;\">\n" +
                                "                                            <div class=\"wrap\">\n" +
                                "                                                <span>实名认证</span>\n" +
                                "                                                <span>学历认证</span>\n" +
                                "                                                <span>专业认证</span>\n" +
                            "                                            </div>\n" +
                            "                                        </div>\n" +
                            "                                        <!--下-->\n" +
                            "\n" +
                            "                                    </div>\n" +
                            "                                    <!--内容结束-->\n" +
                            "\n" +
                            "                                </div>\n" +
                            "                            </div>\n" +
                            "                        </div>\n" +
                            "\n" +
                            "                    </div>"+" </a>";

                    }
                    $("#list").append(str);
                }
                else{
                    str += "<div class=\"weui-cells__title\" style=\"line-height: 50px;text-align: center;border-top:1px solid #e4e4e4;margin-bottom:0px;margin-top: 0px\" >暂无更多数据</div>";
                    $("#list").append(str);
                    loading = true;
                }

                $(".weui-loadmore").hide();
            }
        });


    }

    function loadlist1() {
        console.log("sort:"+sort);
        console.log("grade:"+grade);
        console.log("city:"+city);
        console.log("screensex:"+screensex);
        console.log("screenedu:"+screenedu);
        var str = "";
        $.ajax({
            type:"post",
            url:"{:url('/portal/Type/type')}",
            dataType:'JSON',
            data:{sort:sort,grade:grade,city:city,screensex:screensex,screenedu:screenedu,sub:"{$Request.param.subject}",page:pages},
            error: function (data){
                $(".weui-loadmore").hide();
                str += "<div class=\"weui-cells__title\" style=\"line-height: 50px;text-align: center;border-top:1px solid #e4e4e4;margin-bottom:0px;margin-top: 0px\" >暂无更多数据</div>";
                $("#list").html(str);
            },
            success: function (data) {
                if (data.length > 0){
                    $("#zs").hide();
                    $(".content").show();
                    console.log(data);
                    for(var k in data){
                        str=str+" <a style=\"text-decoration:none;color:black\" href=\"{:url('/portal/detail/detail/id/')}"+data[k].id+"\">"+
                                "    <div data-external=\"actioncode=list\">\n" +
                                "                        <div class=\"item\" data-id=\"785349041\" data-external=\"actioncode=list\" style=\"border:none\">\n" +
                                "                            <div class=\"border_wrap\">\n" +
                                "                                <div class=\"header cf rel\">\n" +
                                "\n" +
                                "                                    <!--头像开始-->\n" +
                                "                                    <div class=\"rel img\">\n" +
                                "                                        <img src=\"__TMPL__/public/assets/images/demo/techer1.jpg\"\n" +
                                "                                             alt=\"暂无图片\" class=\"fl\">\n" +
                                "                                    </div>\n" +
                                "                                    <!--头像结束-->\n" +
                                "\n" +
                                "                                    <!--内容开始-->\n" +
                                "                                    <div class=\"info\">\n" +
                                "\n" +
                                "                                        <!--上 介绍-->\n" +
                                "                                        <div class=\"rel cf nick_wrap\">\n" +
                                "                                            <div class=\"price-wrap abs bold\">\n" +
                                "                                                <h1 class=\"bold\">¥"+data[k].price+"<span> 起</span></h1>\n" +
                                "                                            </div>\n" +
                                "                                            <span class=\"txt ellipsis  \">"+data[k].grade+ data[k].subject+ data[k].name+"老师</span>\n" +
                                "                                        </div>\n" +
                                "                                        <!--上-->\n" +
                                "\n" +
                                "                                        <!--中 时间-->\n" +
                                "                                        <div class=\"t_info\" style=\"margin-top: 4px;\">\n" +
                                "                                            <span style=\"color: #ffb812;font-size: 15px\">★★★★★</span> <span>授课"+data[k].teach_time+"小时</span> | <span>教龄"+data[k].school_age+"年</span>\n" +
                                "                                        </div>\n" +
                                "                                        <!--中-->\n" +
                                "\n" +
                                "                                        <!--下 标签-->\n" +
                                "                                        <div class=\"extra_tags cf\" style=\"margin-top: 9px;\">\n" +
                                "                                            <div class=\"wrap\">\n" +
                                "                                                <span>实名认证</span>\n" +
                                "                                                <span>学历认证</span>\n" +
                                "                                                <span>专业认证</span>\n" +
                                "                                            </div>\n" +
                                "                                        </div>\n" +
                                "                                        <!--下-->\n" +
                                "\n" +
                                "                                    </div>\n" +
                                "                                    <!--内容结束-->\n" +
                                "\n" +
                                "                                </div>\n" +
                                "                            </div>\n" +
                                "                        </div>\n" +
                                "\n" +
                                "                    </div>"+" </a>";
                    }
                    $("#list").html(str);
                }
                else{
                    $(".content").hide();
                    str += "<div style='background-color: #eeefef' class=\"mui-content\">\<div><img  style=\"width: 100%;height: 50%;\" src=\"__TMPL__/public/assets/images/zw.png\" /></div></div>";
                    $("#zs").html(str);
                    $("#zs").show();
                    loading = true;
                }

                $(".weui-loadmore").hide();
            }
        });

        //sort grade city选中一个筛选条件
        // else if($.trim(c2)=="c2null"&&$.trim(c1)!="c1null"){
        //     var str = "";
        //     $.ajax({
        //         type:"post",
        //         url:"{:url('/portal/Type/type')}",
        //         dataType:'JSON',
        //         data:{c:c1,sub:"{$Request.param.subject}",f:flag,page: pages},
        //         error: function () {
        //             $(".weui-loadmore").hide();
        //             str += "<div class=\"weui-cells__title\" style=\"line-height: 50px;text-align: center;border-top:1px solid #e4e4e4;margin-bottom:0px;margin-top: 0px\" >暂无更多数据</div>";
        //             $("#list").append(str);
        //         },
        //         success: function (data) {
        //             // console.log(data);
        //             var str='';
        //             for(var k in data){
        //                 str=str+" <a href=\"{:url('/portal/detail/detail/id/')}"+data[k].id+"\">"+"    <div data-external=\"actioncode=list\">\n" +
        //                     "                        <div class=\"item\" data-id=\"785349041\" data-external=\"actioncode=list\">\n" +
        //                     "                            <div class=\"border_wrap\">\n" +
        //                     "                                <div class=\"header cf rel\">\n" +
        //                     "\n" +
        //                     "                                    <!--头像开始-->\n" +
        //                     "                                    <div class=\"rel img\">\n" +
        //                     "                                        <img src=\"\"\n" +
        //                     "                                             alt=\"暂无图片\" class=\"fl\">\n" +
        //                     "                                    </div>\n" +
        //                     "                                    <!--头像结束-->\n" +
        //                     "\n" +
        //                     "                                    <!--内容开始-->\n" +
        //                     "                                    <div class=\"info\">\n" +
        //                     "\n" +
        //                     "                                        <!--上 介绍-->\n" +
        //                     "                                        <div class=\"rel cf nick_wrap\">\n" +
        //                     "                                            <div class=\"price-wrap abs bold\">\n" +
        //                     "                                                <h1 class=\"bold\">¥"+data[k].price+"<span> 起</span></h1>\n" +
        //                     "                                            </div>\n" +
        //                     "                                            <span class=\"txt ellipsis  \">"+data[k].grade+ data[k].subject+ data[k].name+"老师</span>\n" +
        //                     "                                        </div>\n" +
        //                     "                                        <!--上-->\n" +
        //                     "\n" +
        //                     "                                        <!--中 时间-->\n" +
        //                     "                                        <div class=\"t_info\">\n" +
        //                     "                                            <span>授课"+data[k].teach_time+"小时</span> | <span>教龄"+data[k].school_age+"年</span>\n" +
        //                     "                                        </div>\n" +
        //                     "                                        <!--中-->\n" +
        //                     "\n" +
        //                     "                                        <!--下 标签-->\n" +
        //                     "                                        <div class=\"extra_tags cf\">\n" +
        //                     "                                            <div class=\"wrap\">\n" +
        //                     "                                                <span>口语</span>\n" +
        //                     "                                                <span>听力</span>\n" +
        //                     "                                                <span>培养学习习惯</span>\n" +
        //                     "                                                <span>提升解题技巧</span>\n" +
        //                     "                                                <span>小升初</span>\n" +
        //                     "                                                <span>普通话标准</span>\n" +
        //                     "                                                <span>提高学生信心</span>\n" +
        //                     "                                            </div>\n" +
        //                     "                                        </div>\n" +
        //                     "                                        <!--下-->\n" +
        //                     "\n" +
        //                     "                                    </div>\n" +
        //                     "                                    <!--内容结束-->\n" +
        //                     "\n" +
        //                     "                                </div>\n" +
        //                     "                            </div>\n" +
        //                     "                        </div>\n" +
        //                     "\n" +
        //                     "                    </div>"+" </a>";
        //
        //             }
        //             $("#list").append(str);
        //
        //         }
        //     });
        // }
        // //screen中可能选中两个条件的
        // else{
        //     var str = "";
        //     $.ajax({
        //         type:"post",
        //         url:"{:url('/portal/Type/type')}",
        //         dataType:'JSON',
        //         data:{sex:c1,edu:c2,sub:"{$Request.param.subject}",f:flag,page: pages},
        //         error: function () {
        //             $(".weui-loadmore").hide();
        //             str += "<div class=\"weui-cells__title\" style=\"line-height: 50px;text-align: center;border-top:1px solid #e4e4e4;margin-bottom:0px;margin-top: 0px\" >暂无更多数据</div>";
        //             $("#list").append(str);
        //         },
        //         success: function (data) {
        //             // console.log(data);
        //             var str='';
        //             for(var k in data){
        //                 str=str+" <a href=\"{:url('/portal/detail/detail/id/')}"+data[k].id+"\">"+"    <div data-external=\"actioncode=list\">\n" +
        //                     "                        <div class=\"item\" data-id=\"785349041\" data-external=\"actioncode=list\">\n" +
        //                     "                            <div class=\"border_wrap\">\n" +
        //                     "                                <div class=\"header cf rel\">\n" +
        //                     "\n" +
        //                     "                                    <!--头像开始-->\n" +
        //                     "                                    <div class=\"rel img\">\n" +
        //                     "                                        <img src=\"\"\n" +
        //                     "                                             alt=\"暂无图片\" class=\"fl\">\n" +
        //                     "                                    </div>\n" +
        //                     "                                    <!--头像结束-->\n" +
        //                     "\n" +
        //                     "                                    <!--内容开始-->\n" +
        //                     "                                    <div class=\"info\">\n" +
        //                     "\n" +
        //                     "                                        <!--上 介绍-->\n" +
        //                     "                                        <div class=\"rel cf nick_wrap\">\n" +
        //                     "                                            <div class=\"price-wrap abs bold\">\n" +
        //                     "                                                <h1 class=\"bold\">¥"+data[k].price+"<span> 起</span></h1>\n" +
        //                     "                                            </div>\n" +
        //                     "                                            <span class=\"txt ellipsis  \">"+data[k].grade+ data[k].subject+ data[k].name+"老师</span>\n" +
        //                     "                                        </div>\n" +
        //                     "                                        <!--上-->\n" +
        //                     "\n" +
        //                     "                                        <!--中 时间-->\n" +
        //                     "                                        <div class=\"t_info\">\n" +
        //                     "                                            <span>授课"+data[k].teach_time+"小时</span> | <span>教龄"+data[k].school_age+"年</span>\n" +
        //                     "                                        </div>\n" +
        //                     "                                        <!--中-->\n" +
        //                     "\n" +
        //                     "                                        <!--下 标签-->\n" +
        //                     "                                        <div class=\"extra_tags cf\">\n" +
        //                     "                                            <div class=\"wrap\">\n" +
        //                     "                                                <span>口语</span>\n" +
        //                     "                                                <span>听力</span>\n" +
        //                     "                                                <span>培养学习习惯</span>\n" +
        //                     "                                                <span>提升解题技巧</span>\n" +
        //                     "                                                <span>小升初</span>\n" +
        //                     "                                                <span>普通话标准</span>\n" +
        //                     "                                                <span>提高学生信心</span>\n" +
        //                     "                                            </div>\n" +
        //                     "                                        </div>\n" +
        //                     "                                        <!--下-->\n" +
        //                     "\n" +
        //                     "                                    </div>\n" +
        //                     "                                    <!--内容结束-->\n" +
        //                     "\n" +
        //                     "                                </div>\n" +
        //                     "                            </div>\n" +
        //                     "                        </div>\n" +
        //                     "\n" +
        //                     "                    </div>"+" </a>";
        //
        //             }
        //             $("#list").append(str);
        //
        //         }
        //     });
        // }
    }

</script>
</html>